Trends

Exam Review — Trends & Attack Patterns

Cross-cutting patterns observed across all exams (Exams A–F). Use this as a pre-exam mental checklist.


Port Enumeration Priorities

Port Service Why It Matters
80 HTTP (XAMPP) Gobuster for /phpmyadmin — XAMPP default install with blank MySQL root. Webshell upload via SELECT INTO OUTFILE
1433 MSSQL (local) Not always exposed externally — try assumed breach creds locally. "passwords" DB with plaintext domain creds found here
5985 WinRM Primary shell access on all AD hosts
389 / 636 LDAP Enumerate AD objects, users, ACLs
88 Kerberos Confirms DC; also relevant for Kerberoasting

Where Credentials Hide

This is the most consistent pattern across all exams. Every machine had credentials somewhere — the question is where.

Linux

Windows

Active Directory


Initial Foothold Patterns

Pattern 1: Unauthenticated Service → Config File → Credential Reuse → SSH/WinRM

The most common chain. Applies to: rsync, FTP, SMB guest.

rsync/FTP/SMB (no auth) → download everything → find .env / Web.config / DVRParams.ini
    → extract credentials → spray against SSH or WinRM → shell

Seen in: Exam A (.110), Exam D (.110), Exam F (.110) — rsync; Exam D (.111), Exam F (.111) — FTP; Exam A (.111), Exam B (.111) — SMB

Pattern 2: Web App Self-Registration → Sensitive Content Exposure

No authentication bypass needed — the app allows open registration and exposes sensitive files post-login.

Web portal (nginx/IIS) → register account → browse team directory / file areas
    → SSH private key or sensitive attachment → SSH

Seen in: Exam B (.112), Exam C (.112)

Pattern 3: Dir-Busting Web App → Hidden Endpoint → Credential/JWT Leak

IIS or ASP.NET app returning 403 at root. Recursive dir-bust required.

IIS port 80 (403) → feroxbuster (recurse into /backend/api) → /v1/dev (plaintext creds)
    → /v2/users/dev (JWT list) → decode JWTs → extract username:password
    → SMB/RDP spray → shell

Seen in: Exam F (.112)

Pattern 4: WHOIS Username Harvest → POP3 Brute Force → SSH Creds in Email

Specific to boxes with port 43 open. Self-referential credential chain.

Port 43 (WHOIS) → query oscp.exam → extract nic-hdl / e-mail contacts
    → build users.txt → Hydra POP3 spray → login as sysadmin:sysadmin
    → RETR emails → plaintext SSH credentials for another user → SSH

Seen in: Exam C (.110), Exam E (.110)

Pattern 5: vhost Fuzzing → Web App Attack Surface Expansion

Root domain is a decoy or a static site. Helpdesk / support portals live on a hidden vhost.

ffuf vhost fuzz → discover support.domain → register account
    → file upload feature → Burp Content-Type bypass → .aspx RCE

Seen in: Exam A (.112)


Privilege Escalation Patterns

Linux

Linpeas always first. Manual enumeration rarely caught what linpeas found.

Pattern Discovery Method What to Look For
.mysql_history creds linpeas T1552.001 check ALTER USER statements containing root password
dev group membership id find / -group dev 2>/dev/null → config files → log files → API path traversal
NOPASSWD sudo sudo -l After lateral SSH to another user — often NOPASSWD where initial foothold user wasn't
SUID binaries find / -perm -u=s -type f Check against GTFObins
Capabilities getcap -r / 2>/dev/null Less common but worth running

Windows (Standalone)

Pattern Trigger Exploitation
Writable service binary icacls "C:\Program Files\<App>" → (F) for BUILTIN\Users msfvenom reverse shell → replace binary → restart service → SYSTEM
SeManageVolumePrivilege whoami /priv DLL hijack → SeImpersonate → SYSTEM
Application master password Notezilla locked notes on desktop Extract Notes9.db → Base64 SHA256 hash → MDXfind crack → reveals admin password

Argus DVR PrivEsc: If you got in via DVR credentials, Sandra's account has (F) on C:\Program Files\Argus Surveillance DVR. Replace DVRWatchdog.exe with a msfvenom shell, then shutdown /r /t 0 to trigger service restart as SYSTEM.

Active Directory

Host Pattern Tool
External (WS26) whoami /priv → SeDebugPrivilege Mimikatz sekurlsa::logonpasswords → domain creds
External (WS26) whoami /priv → SeBackupPrivilege reg save SAM/SYSTEM → impacket-secretsdump LOCAL
External (WS26) Port 80 open → gobuster → /phpmyadmin XAMPP blank root → SELECT INTO OUTFILE webshell → net localgroup Administrators $USER /add
External (WS26) Local MSSQL (port 1433) impacket-mssqlclient → SELECT from "passwords"."creds" → domain accounts
Internal (SRV22) ACL edge in BloodHound GenericAll over local admin group → net rpc group addmem → impacket-psexec
Internal (SRV22) Lsassy nxc smb $IP -u $USER -p $PASS -M lsassy → pulls Domain Admin credentials
DC SYSTEM via psexec impacket-psexec oscp.exam/$DA_USER:$DA_PASS@$DC_IP

Things to Do on Every Machine

On First Nmap Hit

After Initial Foothold (Linux)

  1. id — check groups, especially dev, developers, docker
  2. find / -group <groupname> 2>/dev/null — follow the group
  3. ss -tnlp — internal services not visible externally (MySQL on 3306, APIs on 8005)
  4. cat ~/.bash_history, cat ~/.mysql_history — credential leaks
  5. Run linpeas before spending time on manual enum
  6. sudo -l — always, even if you expect nothing
  7. find / -perm -u=s -type f 2>/dev/null + getcap -r / 2>/dev/null

After Initial Foothold (Windows)

  1. whoami /priv — SeDebugPrivilege / SeBackupPrivilege / SeManageVolumePrivilege
  2. whoami /groups — check for local admin groups
  3. icacls "C:\Program Files\*" — writable service directories
  4. Check C:\Users\<user>\AppData\Roaming for application databases (Notezilla, etc.)
  5. Check desktop for obvious clues (locked apps, unusual shortcuts)
  6. Look for local services not exposed externally (netstat -ano)

After Initial Foothold (AD — WS26)

  1. whoami /priv — immediately. If nothing useful, move straight to step 2
  2. gobuster dir -u http://$IP — port 80 may be running XAMPP with phpMyAdmin; don't skip it
  3. Connect to local MSSQL: impacket-mssqlclient oscp.exam/$USER:$PASS@$IP -windows-auth
  4. Check all DBs: SELECT name FROM master.dbo.sysdatabases — look for "passwords", "creds"
  5. Run nxc smb <all_IPs> -u $USER -p $PASS --shares with every credential found
  6. Set up Ligolo to reach internal segment (172.16.x.x)
  7. Run BloodHound (SharpHound.exe -c All) as soon as any domain account is confirmed — don't skip this, GenericAll edges were present and were the only lateral path

Credential Spraying Checklist

Every time a new credential is found, spray it immediately across all known services.

nxc smb $ALL_IPS -u users.txt -p passwords.txt --continue-on-success -t 1
nxc winrm $ALL_IPS -u users.txt -p passwords.txt --continue-on-success
nxc ssh $ALL_IPS -u users.txt -p passwords.txt --continue-on-success
nxc mssql $ALL_IPS -u users.txt -p passwords.txt --continue-on-success

Use -t 1 on SMB sprays to avoid lockouts. Add --local-auth separately — local admin credentials sometimes don't work without it.



Observed Failure Modes

Patterns from across all reports where attempts stalled — useful as a "don't waste time here" reference.

Situation What Failed What to Try Instead
MySQL bcrypt hashes dumped Only weak passwords (sarah's) crack with rockyou; admin/developer hashes held across Exams A, D, F, G Accept it — if sarah's cracks, use it; don't burn time on the rest
Replaced admin's bcrypt hash in MySQL with a known one SSH still didn't work after the DB update (Exam A) Hash replacement doesn't affect OS auth — the DB and OS accounts are separate
/etc/passwd write attempt File unwritable even from low-priv user (Exam A) Move on — standard hardened systems don't allow this
developers / dev group membership found find / -group developers ran but no exploitable files (Exams F, G) Not always a dead end — Exam C's dev group led to Nexus config; check what's actually owned by the group
SSH spray after MySQL hash dump hydra -e nsr and nxc ssh with all collected creds — no new accounts (Exam D) If spray fails, only sarah's creds work; pivot to checking internal services instead
dom's Windows privileges Only SeShutdownPrivilege / SeChangeNotifyPrivilege — nothing abusable (Exam A) WinRM access is the objective; PrivEsc on this box may just not be in scope
MSSQL xp_cmdshell Blocked; reconfigure access denied — no SQL-to-RCE path (Exam B) MSSQL is for credential extraction only in these exams; don't expect RCE from it
lsassy hashes didn't auth on SRV22 Pass-the-hash blocked or wrong account scope (Exam G) Crack offline; try plaintext creds from other sources; run BloodHound first
BloodHound failed to run / collect Missed GenericAll edge — the only lateral path to SRV22 in that exam (Exam G) Try bloodhound-python from Kali over the network if SharpHound fails on-host
Silver ticket forgery Complex without correct SPN/keytab; didn't achieve lateral movement (Exam G) Prioritise BloodHound ACL abuse and credential spraying; silver tickets are last resort
winPEAS failed to execute AV / execution policy blocked it (Exam G) powershell -ep bypass, rename the binary, or use WinPEASany.exe

Linked Notes